﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Admin.master" AutoEventWireup="true" CodeFile="Search-Tutor.aspx.cs" Inherits="Search_Tutor"%>


<%@ Register Assembly="obout_ComboBox" Namespace="Obout.ComboBox" TagPrefix="cc1" %>
    
<asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolder1" Runat="Server">

<div>
    <asp:Label ID="Label6" runat="server" Font-Bold="True" Font-Size="Large" 
                    Text=" Danh Sách Gia Sư"  ></asp:Label>
</div>

    <asp:Panel ID="Panel1" runat="server">
        <div>
        <p>
            <asp:Table ID="Table1" runat="server">

            <asp:TableRow>
                <asp:TableCell>
                    <asp:Label ID="Label3" runat="server" Text="Tên"></asp:Label>
                </asp:TableCell>
                <asp:TableCell>                
                    <cc1:ComboBox ID="cboName" runat="server" AllowCustomText="true" EmptyText="" 
                    DataTextField ="Name" DataValueField="Name">
                    </cc1:ComboBox>
                </asp:TableCell>

                <asp:TableCell>
                    <asp:Label ID="Label2" runat="server" Text="Giới Tính"></asp:Label>
                </asp:TableCell>
                <asp:TableCell>
                    <cc1:ComboBox ID="ddlGender" runat="server">
                        <cc1:ComboBoxItem Selected="True" Value="0" Text="Nữ" />
                        <cc1:ComboBoxItem Selected="False" Value="1" Text="Nam" />
                    </cc1:ComboBox>                
                </asp:TableCell>

                <asp:TableCell>
                    <asp:Label ID="Label4" runat="server" Text="Trình Độ"></asp:Label>
                </asp:TableCell>
                <asp:TableCell>                
                    <cc1:ComboBox ID="cboEducation" runat="server" AllowCustomText="true" EmptyText="" 
                    DataTextField ="Education" DataValueField="Education">
                    </cc1:ComboBox>
                </asp:TableCell>
            </asp:TableRow>

            <asp:TableRow>
                <asp:TableCell>
                    <asp:Label ID="Label5" runat="server" Text="Trường"></asp:Label>
                </asp:TableCell>
                <asp:TableCell>
                    <cc1:ComboBox ID="cboUniversity" runat="server" AllowCustomText="true" EmptyText="" 
                    DataTextField ="University" DataValueField="University">
                    </cc1:ComboBox>
                </asp:TableCell>

                <asp:TableCell>
                    <asp:Label ID="Label8" runat="server" Text="Ngành Học"></asp:Label>
                </asp:TableCell>
                <asp:TableCell>
                    <cc1:ComboBox ID="cboSpecialize" runat="server" AllowCustomText="true" EmptyText="" 
                    DataTextField ="Specialize" DataValueField="Specialize">
                    </cc1:ComboBox>
                </asp:TableCell>

                <asp:TableCell>
                    <asp:Label ID="Label7" runat="server" Text="Địa chỉ email"></asp:Label>
                </asp:TableCell>
                <asp:TableCell>
                     <cc1:ComboBox ID="cboEmail" runat="server" AllowCustomText="true" EmptyText="" 
                    DataTextField ="Email" DataValueField="Email">
                    </cc1:ComboBox>
                </asp:TableCell>
            </asp:TableRow>
            <asp:TableRow> 
                <asp:TableCell>
                    <asp:Label ID="lblSubjects" runat="server" Text="Bộ Môn"></asp:Label>
                </asp:TableCell>
                <asp:TableCell>                   
                   <asp:TextBox ID="tbxSubjects" runat="server" CssClass="text-input" ></asp:TextBox>
                </asp:TableCell>

                <asp:TableCell>
                    <asp:Label ID="lblSalary_Start" runat="server" Text="Mức Lương Lớn Hơn"></asp:Label>
                </asp:TableCell>
                <asp:TableCell>
                    <asp:TextBox ID="tbxSalary_Start" runat="server" CssClass="text-input" ></asp:TextBox>  
                </asp:TableCell>

                <asp:TableCell>
                    <asp:Label ID="Label11" runat="server" Text="Mức Lương Nhỏ Hơn"></asp:Label>
                </asp:TableCell>
                <asp:TableCell>
                    <asp:TextBox ID="tbxSalary_End" runat="server" CssClass="text-input" ></asp:TextBox>
                </asp:TableCell>
            </asp:TableRow>

            </asp:Table>        
            <asp:Button ID="btnSearch" runat="server" Text="Tìm kiếm" 
                onclick="btnSearch_Click" CssClass = "button" />
        </p>
    
    </div>

    <div>
            <asp:GridView ID="GridView1" runat="server" AutoGenerateColumns="False" 
                          OnPageIndexChanging="GridView1_PageIndexChanging" OnSorting="GridView1_Sorting" AllowPaging="true">
                <Columns>
                    <asp:BoundField DataField="ID" HeaderText="ID" SortExpression="ID" />    
                    <asp:TemplateField HeaderText="Họ và Tên" SortExpression= "Name" >
                        <ItemTemplate  >
                            <a href='/Tutor-Profile.aspx?id=<%# Eval("ID") %>'><%# Eval("Name") %></a>                        
                        </ItemTemplate>
                    </asp:TemplateField>                
                    <asp:TemplateField HeaderText="Giới Tính" SortExpression="Gender">
                        <ItemTemplate>                       
                            <asp:Label ID="Label1" runat="server" Text=' <%# Eval("Gender") %> '></asp:Label>
                        </ItemTemplate>
                    </asp:TemplateField>                    
                    <asp:BoundField DataField="Education" HeaderText="Trình Độ" SortExpression="Education" />
                    <asp:BoundField DataField="University" HeaderText="Trường" SortExpression="University" />
                    <asp:BoundField DataField="Specialize" HeaderText="Ngành Học" SortExpression="Specialize" />                    
                    <asp:BoundField DataField="Mark" HeaderText="Điểm" SortExpression="Mark" />                    
                    <asp:BoundField DataField="Experience" HeaderText="Kinh Nghiệm" SortExpression="Experience" />
                    <asp:BoundField DataField="Salary" HeaderText="Lương" SortExpression="Salary" />

                </Columns>
            </asp:GridView>
    </div>

    <div>    
        <asp:Button ID="btnExportToExcel" runat="server" Text="Xuất ra file Excel" 
        CssClass = "button" onclick="btnExportToExcel_Click" />
    </div>

    </asp:Panel>

</asp:Content>

